<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <title>东方韵 中国丽人秀·深圳站</title>
        <meta name="description" content="">
        <meta name="keywords" content="">
        <meta name="author" content="众测天下@zhongcetianxia.com">
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
        <meta name="renderer" content="webkit">
        <meta http-equiv="Cache-Control" content="no-transform"/>
        <meta http-equiv="Cache-Control" content="no-siteapp" />
        <meta name="apple-mobile-web-app-capable" content="yes">
        <meta name="apple-mobile-web-app-status-bar-style" content="black">
        <link href="//cdn.bootcss.com/light7/0.4.3/css/light7.min.css" rel="stylesheet">
        <style type="text/css">
            html {
                font-size: 20px;
            }
            @media only screen and (max-width: 320px) {
                html {
                    font-size: 16px !important;
                }
            }
            @media only screen and (min-width: 375px) {
                html {
                    font-size: 18px !important;
                }
            }
            @media only screen and (min-width: 400px) {
                html {
                    font-size: 19.2px !important;
                }
            }
            @media only screen and (min-width: 414px) {
                html {
                    font-size: 19.872px !important;
                }
            }
            @media only screen and (min-width: 480px) {
                html {
                    font-size: 23.04px !important;
                }
            }
            img{max-width: 100%;}
            /*public*/
            .text-center{text-align: center;}
            .ai-top { -webkit-box-align: start!important; -webkit-align-items: flex-start!important; align-items: flex-start!important; }
            /*before after*/
            .before-no:before { height: 0!important; background-color: transparent!important }
            .after-no:after { height: 0!important; background-color: transparent!important }
            .b-no{border:0!important }
            .m-no { margin: 0!important; }
            .mt-no { margin-top: 0!important; }
            .r-sm { -moz-border-radius: 0.25rem!important; -webkit-border-radius: 0.25rem!important; border-radius: 0.25rem!important; overflow: hidden }
            .r-round { -moz-border-radius: 0.75rem!important; -webkit-border-radius: 0.75rem!important; border-radius: 0.75rem!important; overflow: hidden }
            .r-circle { -moz-border-radius: 50%!important; -webkit-border-radius: 50%!important; border-radius: 50%!important; overflow: hidden }
            .list-block > ul > li {border-bottom: 1px solid #f1f1f1;}
            .list-block > ul > li:last-child {border-bottom:0;}
            /*thumb*/
            .thumb-1x { width: 2.4rem }
            .thumb-2x { width: 3.2rem }
            .thumb-3x { width: 4.0rem }
            /*fixed*/
            .fixed-top { position: fixed; left: 0; top: 0; right: 0; z-index: 99 }
            .fixed-bottom { position: fixed; left: 0; right: 0; bottom: 0; z-index: 99 }
            .fixed-bottom~.content {bottom: 3.8rem;}
            /*color*/
            .color-white{color:#fff!important;}
            .color-grey { color: #ABABAB!important; }
            .color-main { color: #03AB9E!important; }
            .color-sub { color: #59BFFD!important; }
            .color-sub-dark { color: #2AAEEC!important; }
            .bg-grey { background-color: #f7f7f8!important; }
            .bg-dark{background-color: #999999!important;}
            .bg-white { background-color: #ffffff!important; }
            .bg-main{background-color:#02CFC1!important;}
            .bg-main-dark{background-color:#03AB9E!important;}
            .bg-main-light{background-color:#CCECFF!important;}
            .bg-sub{background-color: #59BFFD}
            .bg-sub-dark{background-color: #2AAEEC}
            .bg-sub-light{background-color: #59BFFD}
            /*font-size*/
            .fs-sm { font-size: 0.50rem!important; }
            .fs-0x { font-size: 0.65rem!important; }
            .fs-1x { font-size: 0.75rem!important; }
            .fs-2x { font-size: 0.95rem!important; }
            .fs-3x { font-size: 1.15rem!important; }
            /*text*/
            .text-nowrap-1x { display: -webkit-box; overflow: hidden; text-overflow: ellipsis; -webkit-box-orient: vertical; -webkit-line-clamp: 1; -webkit-box-flex: 1; height: inherit; }
            .text-nowrap-2x { display: -webkit-box; overflow: hidden; text-overflow: ellipsis; -webkit-box-orient: vertical; -webkit-line-clamp: 2;-webkit-box-flex: 2; height: inherit; }
            .text-nowrap-3x { display: -webkit-box; overflow: hidden; text-overflow: ellipsis; -webkit-box-orient: vertical; -webkit-line-clamp: 3;-webkit-box-flex: 3; height: inherit; }
            .text-nowrap-4x { display: -webkit-box; overflow: hidden; text-overflow: ellipsis; -webkit-box-orient: vertical; -webkit-line-clamp: 4;-webkit-box-flex: 4; height: inherit; }
            .text-nowrap-5x { display: -webkit-box; overflow: hidden; text-overflow: ellipsis; -webkit-box-orient: vertical; -webkit-line-clamp: 5;-webkit-box-flex: 5; height: inherit; }
            /*overwrite*/
            .content-padded{margin-left:0.75rem;margin-right: 0.75rem;}
            /*当前页*/
            .list-no-border{border:0!important;}
            .list-no-border .item-inner{border-bottom: 0!important}
            .list-block.list-no-border > ul > li {border-bottom: 0}
            .wrap { /*position: fixed; left: 0; bottom: 0; right: 0; top: 0; min-height: 100vh;*/ width:100%;background: url("__PUBLIC__/widget/vote/images/vote/body_bg.png") top center repeat-y #aa34bf; background-attachment: fixed;background-size: 100% auto;/*z-index: -2;*/ }
            .wrap-body{background-color: #fff;padding:0 0.75rem 0.75rem 0.75rem;-moz-box-shadow: 0 0.05rem 0.1rem rgba(0, 0, 0, 0.1); -webkit-box-shadow: 0 0.05rem 0.1rem rgba(0, 0, 0, 0.1); box-shadow: 0 0.05rem 0.1rem rgba(0, 0, 0, 0.1);}
            .page > .content{background: url("__PUBLIC__/widget/vote/images/vote/body_bg.png") center repeat-y;background-color:#aa34bf }
            /*popup*/
            .popup-header{position: relative;/*background-color: #59BFFD;color:#fff;*/color:#2CBAF5;height:2.4rem;line-height: 2.4rem;padding-left: 0.75rem;padding-right: 0.75rem;}
            .popup-header h3{font-size:0.8rem;}
            .popup-header .close-popup{position: absolute;right:0.55rem;top:0;font-size: 1.25rem;/*color:#fff;*/}
            /*popup*/
            .popup-wrap{display: inline-block;width:90%;max-width:100%;height:17rem;background: url("__PUBLIC__/widget/vote/images/vote/popupBg.png") bottom center no-repeat;background-size: 100% 100%;background-color: transparent;border:none!important;margin-top: 0rem;margin-bottom: 1.0rem;}
            .popup-wrap2{display: inline-block;width:90%;max-width:100%;height:17rem;background: url("__PUBLIC__/widget/vote/images/vote/popupBg2.png") bottom center no-repeat;background-size: 100% 100%;background-color: transparent;border:none!important;margin-top: 0rem;margin-bottom: 1.0rem;}
            .popup-wrap3{display: inline-block;width:90%;max-width:100%;height:17rem;background: url("__PUBLIC__/widget/vote/images/vote/popupBg3.png") bottom center no-repeat;background-size: 100% 100%;background-color: transparent;border:none!important;margin-top: 0rem;margin-bottom: 1.0rem;}
            .popup-body{padding:2.65rem 0.75rem 0.75rem 0.75rem;color: #8B4B23}
            a.close-popup{display: inline-block;width:1.25rem;max-width:100%;height:1.25rem;line-height:1.25rem;background: url("__PUBLIC__/widget/vote/images/xws/btn-close.png") bottom center no-repeat;background-size: 100% 100%;background-color: transparent;border:none!important;text-align: center;color: #fff;outline: none;color:#fff;}
            .modal-overlay, .popup-overlay, .preloader-indicator-overlay{background: rgba(0,0,0,.7);}
            /*icon*/
            .zc { width: 1.0rem; min-height: 1.0rem; display: inline-block; vertical-align: middle; background-size: 100% auto!important; }
            .zc-big{width: 1.2rem; min-height: 1.2rem;}
            .zc_clock {background: url("__PUBLIC__/widget/vote/images/icon_clock.png") center no-repeat;}
            /*button*/
            .btn-warning{display: inline-block;width:12.5rem;max-width:100%;height:2.25rem;line-height:2.25rem;background: url("__PUBLIC__/widget/vote/images/xws/btn-warning.png") bottom center no-repeat;background-size: 100% 100%;background-color: transparent;border:none!important;text-align: center;color: #fff;outline: none;}
            .btn-warning-md{display: inline-block;width:100%;max-width:100%;height:2.25rem;line-height:2.25rem;color: #fff;font-size: 1.1rem;background-color: #fc8f00; border: none;}
            .btn-warning-sm{display: inline-block;width:3.65rem;max-width:100%;height:1.35rem;line-height:1.35rem;background: url("__PUBLIC__/widget/vote/images/xws/btn-warning-sm.png") bottom center no-repeat;background-size: 100% 100%;background-color: transparent;border:none!important;text-align: center;color: #fff;outline: none;}
            .action-block{margin-top: 1.0rem;margin-bottom: 0.3rem;}
            button.disabled{background-image: none;background-color:#EEEEEE;color:#aaa;-moz-border-radius: 0.5rem!important; -webkit-border-radius: 0.5rem!important; border-radius: 0.5rem!important; overflow: hidden }
            /*line-title*/
            .slogan{margin-left:1.55rem;margin-top:1.0rem;padding-bottom: 0.75rem;}
            .line{content:"";display:inline-block;width: 1.5rem;height: 0.05rem;background-color:#59BFFD;vertical-align: middle;}
            .line-title{margin-left: 0.5rem;margin-right: 0.5rem;}

            /*新卡片的样式*/
            .card{
                /*border-radius: 10px;*/
                background-color: transparent;
                border-bottom-right-radius: 8px;
                border-bottom-left-radius: 8px;
            }
            .card-header{
                border-bottom: none;
                background: url("__PUBLIC__//widget/vote/images/vote/detail_top_banner.png") top center no-repeat;
                background-color: transparent;
                /*background-attachment: fixed;*/
                background-size: 103% auto;
                height: 3rem;
                /*text-align: center;*/
                color: #fff;
            }
            .card-content{
                background-color: #fff;
            }
            .card-footer{
                border-top: none;
                font-size: 0.9rem;
                padding-left: 2rem;
                background-color: #fff;
                border-bottom-right-radius: 8px;
                border-bottom-left-radius: 8px;
            }

            .bar-tab{
                background-color: #fc8f00;
            }

            .btn-warning-share{top:10rem;position: relative;display: inline-block;width:30%;max-width:100%;height:2.25rem;line-height:2.25rem;color: #fff;font-size: 1.1rem;background-color: #fc8f00;border-radius: 10px;}
            .btn-warning-ranks{display: inline-block;width:90%;max-width:100%;height:2.25rem;line-height:2.25rem;color: #fff;font-size: 1.0rem; background-color: #67abfe; border: none; border-radius: 13px;}
            .btn-warning-votes{display: inline-block;width:90%;max-width:100%;height:2.25rem;line-height:2.25rem;color: #fff;font-size: 1.0rem;background-color: #ff60ee; border: none;border-radius: 13px;}
            .user-name{
                color:#ff6c61;
                top:-0.6rem;
                position: relative;
                width: 7rem;
                display: inline-flex;
                height: 1rem;
                overflow: hidden;
            }
            .user-avatar{
                border-radius: 100%;
            }
            .vote-date{
                position: relative;
                top:0.6rem;
                color:#8a8a8a;
            }
            .vote-text{
                float: right;
                margin-right: 10px;
                position: relative;
                top:0.6rem;
                color:#8a8a8a;
            }

            @media screen and (max-width: 360px){
                .user-name{
                    width: 5.5rem;

                }
                .vote-date{
                    top:0.2rem;
                }
                .vote-text{
                    top:0.2rem;
                }
                .popup-wrap3{
                    width: 100%;
                }
                .popup-wrap2{
                    width: 100%;
                }
                .popup-wrap{
                    width: 100%;
                }
                .card-content-inner{
                    padding-left: 0.7rem;
                }
            }

        </style>
    </head>
    <body>
        <div class="page">
            <div class="content"> 
                <div class="wrap clearfix">     
                    <!--<div class="slogan clearfix"><img src="__PUBLIC__/widget/vote/images/vote/slogan.png" style="width: 11.75rem"></div>-->
                    <div class="card">

                        <div class="card-content" style="border-radius:10px;">
                            <div class="card-content-inner">

                                <img src="{$product.thumb}" style="width: 100%; height: 100%;"> 
                            </div>
                            <div class="card-content-inner row">
                                <div class="col-33" style=" background-color: #6abdff;padding: 0.2rem; margin-left: 0; color: #FFF; text-indent: 0.8rem; border-bottom-right-radius: 10px; border-top-right-radius: 10px;">{$product.vote_num} 号</div>
                                <div class="col-66" style=" background-color: #fff;padding: 0.2rem; margin-left: 0; color: #000; text-indent: 0.8rem;">{$product.name} </div>
                            </div>
                            <div class="card-content-inner row">
                                <div class="col-33" style=" padding: 0.2rem; margin-left: 0;  text-indent: 0.8rem;color: #000;">美丽宣言:</div>
                                <div class="col-66" style=" background-color: #fff;padding: 0.2rem; margin-left: 0; color: #000; ">{$product.slogan}</div>
                            </div>

                        </div>

                    </div>



                    <div style="height:10px;">



                    </div>

                    <div class="card">

                        <div class="card-content" style="border-radius:10px;">

                            <div class="card-content-inner">
                                <div class="row">
                                    <div class="card-content-inner col-50" style="font-size:1rem; text-align: center;">

                                        排名: <label style="color:#ff60ee;">{$ranks}</label>


                                    </div>
                                    <div class="card-content-inner col-50" style="font-size:1rem; text-align: center;">
                                        票数: <label id="vote_number" style="color:#ff60ee;">{$product.votes}</label>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="card-content-inner col-50">

                                        <button type="button" class="btn btn-warning-ranks" id="share_it_btn">拉票</button>


                                    </div>
                                    <div class="card-content-inner col-50">
                                        <button type="button" class="btn btn-warning-votes" id="vote_it_btn">投她一票</button>
                                    </div>
                                </div>
                            </div>


                        </div>

                    </div>



                    <div style="height:10px;">



                    </div>

                    <div class="card">
                        <div class="card-header text-center">她的支持者</div>
                        <div class="card-content">
                            <div class="card-content-inner">

                            </div>
                            <empty name="votes">
                                <div style="color:#ccc;text-align:center;">她还没有支持者</div>
                                <else/>
                                <volist name='votes' id='vo'>
                                    <div class="row" style="margin-top: 0.5rem;">
                                        <div class="col-50">
                                            <span style=""><img class="user-avatar" src="{$vo.avatar}" style="width: 1.5rem; height: 1.5rem; margin-left: 0.5rem;"/></span>
                                            <span class="user-name">{$vo.username}</span>
                                        </div>

                                        <div class="col-50">
                                            <span class="vote-date">{$vo.ctime|date="Y-m-d",###}</span>
                                            <span class="vote-text" >投了一票</span>
                                        </div>
                                    </div>
                                </volist>
                            </empty>


                        </div>
                        <div class="card-footer">


                        </div>
                    </div>
                    <div style="height:20px;">

                    </div>
                    
                    <div class="card">
                        <div class="card-content">
                            <div class="card-content-inner" style="padding:0;">

                                <img src="http://cdns.zhongcetianxia.com/dfy/images/dfy_bg.jpg" style="width: 100%; height: 100%;"> 
                            </div>

                        </div>
                        <div class="card-footer">


                        </div>
                    </div>
                    <div style="height:50px;">

                    </div>
                    
                </div>
            </div>

        </div>
        <!-- 成功投票弹窗 -->
        <div class="popup popup-finsh close-popup" style="background-color: transparent;">
            <div class="content-block text-center">
                <div class="popup-wrap">
                    <div class="popup-body">

                    </div>
                </div>
            </div>
        </div>

        <!--已经投票的弹窗-->
        <div class="popup popup-finsh2 close-popup" style="background-color: transparent;">
            <div class="content-block text-center">
                <div class="popup-wrap2">
                    <div class="popup-body">

                    </div>
                </div>
            </div>
        </div>

        <!--拉票-->
        <div class="popup popup-finsh3 close-popup" style="background-color: transparent;">
            <div class="content-block text-center">
                <div class="popup-wrap3">
                    <div class="popup-body">

                    </div>
                </div>
            </div>
        </div>


        <script type="text/javascript" src="//cdn.bootcss.com/jquery/1.8.3/jquery.min.js"></script>
        <script type="text/javascript">$.config = {router: false}</script>
        <script src="//cdn.bootcss.com/light7/0.4.3/js/light7.min.js"></script>
        <script type="text/javascript">$.init();</script>
        <script type="text/javascript">
            $("#vote_it_btn").on('click', function (event) {
            event.preventDefault();
            /* Act on the event */
            // if(sessionStorage.voted==1){
            //   $('.popup-title').text('您今天已经投过票啦！');
            // }
            // $.popup('.popup-finsh');
            // sessionStorage.voted=1;//投票标记

            var mid = {$mid};
            var pid = {$product.pid};
            var vid = {$product.vid};
            var url = "{:U('vote_it')}";
            var now_url = window.location.href;
            $.ajax({
            type: 'post',
                    url: url,
                    data: {mid: mid, pid: pid, vid: vid},
                    dataType: 'json',
                    success: function (data) {
                    if (data.err == 0) {
                    //成功投票

//                            页面上的数字变化
                    var vote_number = parseInt($("#vote_number").text());
                    vote_number++;
                    $("#vote_number").text(vote_number);
                    console.log(vote_number);
                    $.popup('.popup-finsh');
                    //window.location.href = now_url;
                    } else {
//                            已经投票
                    $.popup('.popup-finsh2');
                    //alert(data.msg);
                    }

                    }
            });
            });
            $("#share_it_btn").on('click', function (event) {
            event.preventDefault();
            $.popup('.popup-finsh3');
            });
        </script>
        <!--微信分享-->
        <script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
        <script>
            //分享

            wx.config({
            debug: false,
                    appId: '{$signPackage["appId"]}',
                    timestamp: {$signPackage["timestamp"]},
                    nonceStr: '{$signPackage["nonceStr"]}',
                    signature: '{$signPackage["signature"]}',
                    jsApiList: [
                            // 所有要调用的 API 都要加到这个列表中
                            'onMenuShareTimeline',
                            'onMenuShareAppMessage'
                    ]
            });
            wx.ready(function () {
            // 在这里调用 API
            wx.onMenuShareTimeline({
            title: '{$wx_share.timeline_title}', // 分享标题
                    desc: '{$wx_share.desc}', // 分享描述
                    link: "{$wx_share.link}", // 分享链接
                    imgUrl: "{$wx_share.logo}", // 分享图标
                    success: function () {
                    // 用户确认分享后执行的回调函数，生成红包

                    },
                    cancel: function () {
                    // 用户取消分享后执行的回调函数
                    }
            });
            wx.onMenuShareAppMessage({
            title: '{$wx_share.title}', // 分享标题
                    desc: '{$wx_share.desc}', // 分享描述
                    link: "{$wx_share.link}", // 分享链接
                    imgUrl: "{$wx_share.logo}", // 分享图标
                    type: '', // 分享类型,music、video或link，不填默认为link
                    dataUrl: '', // 如果type是music或video，则要提供数据链接，默认为空
                    success: function () {
                    // 用户确认分享后执行的回调函数

                    },
                    cancel: function () {
                    // 用户取消分享后执行的回调函数
                    }
            });
            });

        </script>
    </body>
</html>